package py.com.alfa.escriba.web.services;

import java.util.List;

import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import py.com.alfa.escriba.exception.ServiceException;
import py.com.alfa.escriba.persistence.dto.EscribanosDTO;
import py.com.alfa.escriba.web.interceptor.InvocationContext;

public interface EscribanosService {
  List<EscribanosDTO> listEscribanos(InvocationContext ic) throws ServiceException;
  EscribanosDTO getEscribanos(Long id, InvocationContext ic) throws ServiceException;
  void deleteEscribanos(Long id, InvocationContext ic) throws ServiceException;
  @Transactional(value="transactionManager", rollbackFor={ServiceException.class},propagation=Propagation.REQUIRED)
  EscribanosDTO updateEscribanos(Long id, EscribanosDTO dto, InvocationContext ic) throws ServiceException;
  @Transactional(value="transactionManager", rollbackFor={ServiceException.class},propagation=Propagation.REQUIRED)
  EscribanosDTO createEscribanos(EscribanosDTO dto, InvocationContext ic) throws ServiceException;
}